package com.ruoyi.xst.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.xst.mapper.MeetingHardwareMapper;
import com.ruoyi.xst.domain.MeetingHardware;
import com.ruoyi.xst.service.IMeetingHardwareService;

/**
 * 会议门牌Service业务层处理
 * 
 * @author Rambo
 * @date 2024-11-21
 */
@Service
public class MeetingHardwareServiceImpl implements IMeetingHardwareService 
{
    @Autowired
    private MeetingHardwareMapper meetingHardwareMapper;

    /**
     * 查询会议门牌
     * 
     * @param id 会议门牌主键
     * @return 会议门牌
     */
    @Override
    public MeetingHardware selectMeetingHardwareById(Long id)
    {
        return meetingHardwareMapper.selectMeetingHardwareById(id);
    }

    /**
     * 查询会议门牌列表
     * 
     * @param meetingHardware 会议门牌
     * @return 会议门牌
     */
    @Override
    public List<MeetingHardware> selectMeetingHardwareList(MeetingHardware meetingHardware)
    {
        return meetingHardwareMapper.selectMeetingHardwareList(meetingHardware);
    }

    /**
     * 新增会议门牌
     * 
     * @param meetingHardware 会议门牌
     * @return 结果
     */
    @Override
    public int insertMeetingHardware(MeetingHardware meetingHardware)
    {
        meetingHardware.setCreateTime(DateUtils.getNowDate());
        return meetingHardwareMapper.insertMeetingHardware(meetingHardware);
    }

    /**
     * 修改会议门牌
     * 
     * @param meetingHardware 会议门牌
     * @return 结果
     */
    @Override
    public int updateMeetingHardware(MeetingHardware meetingHardware)
    {
        return meetingHardwareMapper.updateMeetingHardware(meetingHardware);
    }

    /**
     * 批量删除会议门牌
     * 
     * @param ids 需要删除的会议门牌主键
     * @return 结果
     */
    @Override
    public int deleteMeetingHardwareByIds(Long[] ids)
    {
        return meetingHardwareMapper.deleteMeetingHardwareByIds(ids);
    }

    /**
     * 删除会议门牌信息
     * 
     * @param id 会议门牌主键
     * @return 结果
     */
    @Override
    public int deleteMeetingHardwareById(Long id)
    {
        return meetingHardwareMapper.deleteMeetingHardwareById(id);
    }
}
